package classes.Commands
{
	import components.editor.c_baseElement;
	
	public class c_indexCommand extends c_baseCommand {
		private var _prevIndex: int;
		private var _setIndex: int;
		public function c_indexCommand(a_element:c_baseElement, a_index: int) {
			super(a_element);
			_prevIndex 	= a_element.index;
			_setIndex	= a_index;
		}
		
		override public function Execute():void {
			element.index = _setIndex;
		}
		
		override public function unExecute():void {
			element.index = _prevIndex;
		}		
	}
}